package com.dnkj.tfeign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

@FeignClient(value = "t-client", fallback = SchedualServiceHiHystric.class)
public interface SchedualServiceHi {
    //如果t-client正常,访问t-client服务下的hi接口,如果t-client挂了,则访问SchedualServiceHiHystric类下的hi接口
    @RequestMapping(value = "/hi",method = RequestMethod.GET)
    String hi();
}
